import React from 'react';
import IndexNav from '../components/IndexNav';
import {Switch,Route,Redirect} from 'react-router-dom'

import Recomment from '../components/index/Recommend'
import Hot from '../components/index/Hot'
import Search from '../components/index/Search'


import MiniPlayView from '../components/MiniPlayView'

class Index extends React.Component{
    render(){
        // console.log(this.props,'index');
        return <div style={{paddingTop:'0.93rem',paddingBottom:'1.3rem'}}>
            <IndexNav></IndexNav>
            <Switch>
                <Route path='/tj' children={()=><Recomment/>}></Route>
                <Route path='/hot' children={()=><Hot/>}></Route>
                <Route path='/search' children={()=><Search/>}></Route>
                <Redirect to='/tj'></Redirect>
            </Switch>
            <MiniPlayView></MiniPlayView>
        </div>
    }
}

export default Index;